<template>
	<view class="my-container">
		<!-- 顶部用户信息区域 -->
		<view class="user-info-section">
			<view class="user-header">
				<view class="user-avatar-name">
					<image src="/static/images/avatar.png" mode="aspectFill" class="avatar"></image>
					<view class="user-name-id">
						<view class="name-tag">
							<text class="name">用户1964</text>
							<text class="tag">老板</text>
						</view>
						<text class="user-id">159*****64</text>
					</view>
				</view>
				<view class="header-right">
					<view class="work-btn">我要找工作</view>
					<view class="settings-btn">
						<image src="/static/images/settings.png" mode="aspectFit"></image>
					</view>
				</view>
			</view>
			
			<!-- 数据统计区域 -->
			<view class="stats-section"> 
				<view class="stat-item">
					<text class="stat-value">0<text class="percent">%</text></text>
					<text class="stat-label">好评率</text>
				</view>
				<view class="stat-item border-line">
					<text class="stat-value">0<text class="unit">单</text></text>
					<text class="stat-label">完成数</text>
				</view>
				<view class="stat-item">
					<text class="stat-value">0<text class="percent">%</text></text>
					<text class="stat-label">24小时结算率</text>
				</view>
			</view>
			
			<!-- 积分区域 -->
			<view class="points-section">
				<view class="points-title">当前正式积分</view>
				<view class="points-content">
					<view class="points-value">
						<image src="/static/images/coin.png" mode="aspectFit" class="coin-icon"></image>
						<text class="value">0</text>
					</view>
					<view class="points-actions">
						<view class="points-detail-btn">积分明细</view>
						<view class="points-exchange-btn">立即购买</view>
					</view>
				</view>
			</view>
			
			<!-- 数据展示区域 -->
			<view class="data-section">
				<view class="data-item">
					<text class="data-value">0</text>
					<text class="data-label">我的发包(个)</text>
				</view>
				<view class="data-item">
					<text class="data-value">0.00</text>
					<text class="data-label">奖励金余额(元)</text>
				</view>
				<view class="data-item">
					<text class="data-value">0</text>
					<text class="data-label">累计支付工资(元)</text>
				</view>
			</view>
		</view>
		
		<!-- 我的服务区域 -->
		<view class="services-section">
			<view class="section-title">我的服务</view>
			<view class="services-grid">
				<view class="service-item" v-for="(item, index) in myServices" :key="index">
					<image :src="item.icon" mode="aspectFit" class="service-icon"></image>
					<text class="service-name">{{item.name}}</text>
				</view>
			</view>
		</view>
		
		<!-- 其他功能区域 -->
		<view class="other-functions-section">
			<view class="section-title">其他功能</view>
			<view class="functions-grid">
				<view class="function-item" v-for="(item, index) in otherFunctions" :key="index">
					<image :src="item.icon" mode="aspectFit" class="function-icon"></image>
					<text class="function-name">{{item.name}}</text>
				</view>
			</view>
		</view>
		
		<!-- 底部信息 -->
		<view class="footer-info">
			<text class="contact-info">客服电话 400-188-6610   工作时间 9:00-18:00</text>
			<text class="disclaimer">招聘过程中与与未成年人零接触原则上</text>
			<view class="license-info">
				<text>营业执照</text>
				<text>人力资源服务许可证</text>
				<text>ICP证书号：沪B2-20211709</text>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return { 
				myServices: [
					{ name: '专属招工经理', icon: '/static/images/my/service1.png' },
					{ name: '联系客服', icon: '/static/images/my/service2.png' },
					{ name: '员工黑名单', icon: '/static/images/my/service3.png' },
					{ name: '费用报销明细', icon: '/static/images/my/service4.png' }
				],
				otherFunctions: [
					{ name: '更换账号', icon: '/static/images/my/function1.png' },
					{ name: '我要找工作', icon: '/static/images/my/function2.png' },
					{ name: '用户服务协议', icon: '/static/images/my/function3.png' },
					{ name: '隐私政策', icon: '/static/images/my/function4.png' },
					{ name: '知识产权规则', icon: '/static/images/my/function5.png' },
					{ name: '邀请码', icon: '/static/images/my/function6.png' },
					{ name: '实名认证', icon: '/static/images/my/function7.png' },
					{ name: '下载APP', icon: '/static/images/my/function8.png' },
					{ name: '招工地址', icon: '/static/images/my/function9.png' }
				]
			}
		},
		methods: {
			
		},
		onLoad() {
			
		}
	}
</script>

<style lang="scss">
	.my-container {
		min-height: 100vh;
		background: #f8f8f8;
		padding-bottom: 30px;
	}
	
	.user-info-section {
		background: #fff;
		padding: 20px 15px;
		margin-bottom: 10px;
		position: relative;
		
		.user-header {
			display: flex;
			justify-content: space-between;
			align-items: center;
			margin-bottom: 20px;
			padding-right: 30px;
			
			.user-avatar-name {
				display: flex;
				align-items: center;
				
				.avatar {
					width: 50px;
					height: 50px;
					border-radius: 50%;
					margin-right: 10px;
					background: #FFD000;
				}
				
				.user-name-id {
					.name-tag {
						display: flex;
						align-items: center;
						margin-bottom: 5px;
						
						.name {
							font-size: 16px;
							font-weight: bold;
							margin-right: 8px;
						}
						
						.tag {
							font-size: 12px;
							color: #3370FF;
							background: #E8F1FF;
							padding: 1px 6px;
							border-radius: 10px;
						}
					}
					
					.user-id {
						font-size: 12px;
						color: #999;
					}
				}
			}
			
			.header-right {
				background: #FFD000;
				color: #333;
				font-size: 12px;
				padding: 4px 10px;
				border-radius: 15px 0 0 15px;
				margin-right: 0;
				border: 1px solid #FF4B33;
				display: flex;
				align-items: center;
				justify-content: space-between;
				position: absolute;
				right: 0;
				top: 20px;
				.work-btn {
					
					
				}
				
				
				.settings-btn {
					margin-left: 8rpx;
					image {
						width: 30rpx;
						height: 30rpx;
					}
				}
			}
		}
		
		.stats-section {
			display: flex;
			justify-content: space-between;
			margin-bottom: 20px;
			background: #f8f8f8;
			border-radius: 8px;
			padding: 15px 0;
			
			.stat-item {
				flex: 1;
				display: flex;
				flex-direction: column;
				align-items: center;
				position: relative;
				
				&.border-line {
					&::before, &::after {
						content: '';
						position: absolute;
						top: 50%;
						transform: translateY(-50%);
						width: 1px;
						height: 60%;
						background-color: #e0e0e0;
					}
					
					&::before {
						left: 0;
					}
					
					&::after {
						right: 0;
					}
				}
				
				.stat-value {
					font-size: 18px;
					font-weight: bold;
					margin-bottom: 5px;
					
					.percent, .unit {
						font-size: 12px;
						font-weight: normal;
					}
				}
				
				.stat-label {
					font-size: 12px;
					color: #999;
				}
			}
		}
		
		.points-section {
			background: #f8f8f8;
			border-radius: 8px;
			padding: 15px;
			margin-bottom: 20px;
			
			.points-title {
				font-size: 14px;
				font-weight: bold;
				margin-bottom: 15px;
			}
			
			.points-content {
				display: flex;
				justify-content: space-between;
				align-items: center;
				
				.points-value {
					display: flex;
					align-items: center;
					
					.coin-icon {
						width: 20px;
						height: 20px;
						margin-right: 5px;
					}
					
					.value {
						font-size: 20px;
						font-weight: bold;
					}
				}
				
				.points-actions {
					display: flex;
					
					.points-detail-btn {
						font-size: 12px;
						color: #666;
						background: #eee;
						padding: 5px 10px;
						border-radius: 15px;
						margin-right: 10px;
					}
					
					.points-exchange-btn {
						font-size: 12px;
						color: #fff;
						background: #FFD000;
						padding: 5px 10px;
						border-radius: 15px;
					}
				}
			}
		}
		
		.data-section {
			display: flex;
			justify-content: space-between;
			
			.data-item {
				flex: 1;
				display: flex;
				flex-direction: column;
				align-items: center;
				
				.data-value {
					font-size: 18px;
					font-weight: bold;
					margin-bottom: 5px;
				}
				
				.data-label {
					font-size: 12px;
					color: #999;
					text-align: center;
				}
			}
		}
	}
	
	.services-section, .other-functions-section {
		background: #fff;
		padding: 15px;
		margin-bottom: 10px;
		
		.section-title {
			font-size: 16px;
			font-weight: bold;
			margin-bottom: 15px;
		}
		
		.services-grid, .functions-grid {
			display: flex;
			flex-wrap: wrap;
			
			.service-item, .function-item {
				width: 25%;
				display: flex;
				flex-direction: column;
				align-items: center;
				margin-bottom: 15px;
				
				.service-icon, .function-icon {
					width: 24px;
					height: 24px;
					margin-bottom: 8px;
				}
				
				.service-name, .function-name {
					font-size: 12px;
					color: #333;
					text-align: center;
				}
			}
		}
	}
	
	.footer-info {
		padding: 0 15px;
		margin-top: 20px;
		
		.contact-info, .disclaimer, .license-info {
			font-size: 12px;
			color: #999;
			text-align: center;
			margin-bottom: 5px;
			line-height: 1.5;
		}
		
		.license-info {
			display: flex;
			flex-direction: column;
			align-items: center;
			
			text {
				margin-bottom: 3px;
			}
		}
	}
</style> 